import requests
import json


# 返回商品筛选的函数
def re_goods_filter(postbody):
    import HenDaFuinterface.InterFace.token as token
    token = token.token()  # 获取token
    headers = {'content-type': 'application/json', 'token': token}  # 请求头
    payload = postbody
    ret = requests.post("http://shop.5913ex.com/api/v1/goodsFilter/getList", data=json.dumps(payload), headers=headers)
    print(ret.text)
    return json.dumps(ret.json(), ensure_ascii=False)




